<?php
declare(strict_types=1);

namespace app\common\model;

use think\Collection;

class RelationAttributeCategory extends CommonBase
{
    public function getAllRelationAttributeCategory(array $where = []): Collection
    {
        $where['is_delete'] = config('status.mysql.table_normal');
        return $this->where($where)->select();
    }

    public function getAllRelationAttributeCategoryByAttributeId(int $attributeId)
    {
        $where = [
            'is_delete'    => config('status.mysql.table_normal'),
            'attribute_id' => $attributeId,
        ];
        return $this->where($where)->select();
    }
}